#!/bin/bash
# 如果编译报错/usr/include/GNUstep/Foundation/Foundation.h:31:9: fatal error: 'objc/objc.h' file not found
# 则需要先加一下链接
# sudo ln -s /usr/lib/gcc/x86_64-linux-gnu/9/include/objc /usr/local/include/objc
clang -o test main.m -I `gnustep-config --variable=GNUSTEP_SYSTEM_HEADERS` \
                       -L `gnustep-config --variable=GNUSTEP_SYSTEM_LIBRARIES` \
                       -lgnustep-base -fconstant-string-class=NSConstantString \
                       -D_NATIVE_OBJC_EXCEPTIONS \
                       -lobjc
